package com.cz.influxdb.config;

import com.influxdb.client.InfluxDBClient;
import com.influxdb.client.InfluxDBClientFactory;

public class InfluxDBHelper {

    private InfluxDBClient influxDBClient;

    public InfluxDBHelper() {
        String url = "http://localhost:8086";
        String token = "cukpifFTPXObxm01SaaBEdTyoJkIWNT1Ccgti3N0uPdd0WFZsq7uKcgjW09AV0fmen3HDJJxGAqnQhV_BTGQbg==";
        String bucket = "root";
        String org = "root";
        influxDBClient = InfluxDBClientFactory.create(url, token.toCharArray(), org, bucket);
    }

    public InfluxDBClient getInfluxDBClient() {
        return influxDBClient;
    }
}


